package com.cloudlinkscm.base.authcenter.assembler;

import com.cloudlinkscm.base.authcenter.model.UserAccount;
import com.cloudlinkscm.base.authcenter.model.dto.UserAccountInfoDto;
import com.cloudlinkscm.loms.framework.core.pojo.SingleAssembler;
import com.cloudlinkscm.loms.framework.util.BeanUtils;
import org.springframework.stereotype.Component;

/**
 * @author : tac
 * @date : 31/07/2017
 */
@Component
public class UserAccount2UserAccountInfoDtoAssembler implements SingleAssembler<UserAccount, UserAccountInfoDto> {

	@Override
    public UserAccountInfoDto assemble(UserAccount from) {
        UserAccountInfoDto to = new UserAccountInfoDto();
        BeanUtils.copyProperties(from, to);
        return to;
    }
}
